package models;

import java.util.Date;

import javax.persistence.Entity;
import javax.persistence.EnumType;
import javax.persistence.Enumerated;
import javax.persistence.Lob;
import javax.persistence.ManyToOne;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;


import play.db.ebean.Model;
import util.TipoArquivo;

@Entity
public class Conteudo extends Model{

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	public String descricao;
	
	@Enumerated(EnumType.STRING)
	public TipoArquivo tipo;
	
	@Lob
	public byte[] arquivo;
	
	public String fonte;
	
	@Temporal(TemporalType.DATE)
	public Date dtCadastro;
	
	
	// ------------------relacionamentos---------------------//
	@ManyToOne
	public Turma turma;
}
